<template>
    <div class="box">
        <div class="bg">
            <div class="desc">
                <h1>你访问的界面不存在！</h1>
                <h4>请检查你的url是否正确，或点击下面按钮回到首页</h4>
                <button @click="goHome">返回到首页</button>
            </div>
        </div>
    </div>
</template>

<script setup lang="ts">
import { useRouter } from 'vue-router';
let $router = useRouter();
const goHome = () => {
    $router.push('/')
}
</script>

<style scoped lang="scss">
.box {
    width: 100vw;
    height: 100vh;
    // background: skyblue;
    background-color: white;

    .bg {
        width: 800px;
        height: 400px;
        background-image: url(@/assets/images/error_images/404.png);
        background-size: 100% 100%;
        margin: 0 auto;
        position: relative;
        top: 10%;

        .desc {
            position: absolute;
            top: 25%;
            right: 0;

            h1 {
                color: #319df9;
                font-size: 30px;
                font-weight: bold;
                line-height: 60px;
            }

            h4 {
                color: #929399;
                font-size: 14px;
                line-height: 50px;
            }

            button {
                color: #fff;
                background-color: #319df9;
                width: 110px;
                height: 38px;
                font-size: 14px;
                border: 0;
                border-radius: 19px;
                text-decoration: underline;
                cursor: pointer;
            }
        }
    }
}
</style>